import { createRouter, createWebHistory, RouteRecordRaw } from "vue-router";
// 异步组件
import { defineAsyncComponent } from 'vue'
import mirror from './mirror'
const Home = () => import('../pages/Home/index.vue')
const result = defineAsyncComponent(() => import('../pages/Home/result.vue'))

const routes: Array<RouteRecordRaw> = [
  {
    path: "/test",
    name: "Home",
    component:  Home,
  },
  {
    path: "/test/result",
    name: "result",
    component:  result,
  },
  ...mirror
]
export default createRouter({
  history: createWebHistory(),
  routes
})